import 'package:flutter/material.dart';
import 'package:top_foundation/top_foundation.dart';

import 'controller.dart';

class NickNamePage extends GetView<NickNameController> {
  const NickNamePage({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: detailAppBar(context, title: '修改昵称'),
      body: Padding(
        padding: EdgeInsets.symmetric(horizontal: 12.r),
        child: Column(
          children: [
            SizedBox(
              height: 20.r,
            ),
            UITextField(
              backgroundColor: Colors.white,
              hintText: '请输入您的昵称',
              style: TextFieldStyle.outLine,
              onChanged: (value) {
                controller.state.name = value;
              },
            ),
            SizedBox(
              height: 50.r,
            ),
            ExpandedFilledButton(
              text: '确定',
              onPressed: controller.sure,
            )
          ],
        ),
      ),
    );
  }
}
